3.69 \(\int \frac{\cos (a+b x^n)}{x} \, dx\)

Optimal. Leaf size=26 \[ \frac{\cos (a) \text{CosIntegral}\left (b x^n\right )}{n}-\frac{\sin (a) \text{Si}\left (b x^n\right )}{n} \]

[Out]

(Cos[a]*CosIntegral[b*x^n])/n - (Sin[a]*SinIntegral[b*x^n])/n

________________________________________________________________________________________

Rubi [A]  time = 0.0339921, antiderivative size = 26, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 3, integrand size = 12, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.25, Rules used = {3378, 3376, 3375} \[ \frac{\cos (a) \text{CosIntegral}\left (b x^n\right )}{n}-\frac{\sin (a) \text{Si}\left (b x^n\right )}{n} \]

Antiderivative was successfully verified.

[In]

Int[Cos[a + b*x^n]/x,x]

[Out]

(Cos[a]*CosIntegral[b*x^n])/n - (Sin[a]*SinIntegral[b*x^n])/n

Rule 3378

Int[Cos[(c_) + (d_.)*(x_)^(n_)]/(x_), x_Symbol] :> Dist[Cos[c], Int[Cos[d*x^n]/x, x], x] - Dist[Sin[c], Int[Si
n[d*x^n]/x, x], x] /; FreeQ[{c, d, n}, x]

Rule 3376

Int[Cos[(d_.)*(x_)^(n_)]/(x_), x_Symbol] :> Simp[CosIntegral[d*x^n]/n, x] /; FreeQ[{d, n}, x]

Rule 3375

Int[Sin[(d_.)*(x_)^(n_)]/(x_), x_Symbol] :> Simp[SinIntegral[d*x^n]/n, x] /; FreeQ[{d, n}, x]

Rubi steps

\begin{align*} \int \frac{\cos \left (a+b x^n\right )}{x} \, dx &=\cos (a) \int \frac{\cos \left (b x^n\right )}{x} \, dx-\sin (a) \int \frac{\sin \left (b x^n\right )}{x} \, dx\\ &=\frac{\cos (a) \text{Ci}\left (b x^n\right )}{n}-\frac{\sin (a) \text{Si}\left (b x^n\right )}{n}\\ \end{align*}

Mathematica [A]  time = 0.0645611, size = 24, normalized size = 0.92 \[ \frac{\cos (a) \text{CosIntegral}\left (b x^n\right )-\sin (a) \text{Si}\left (b x^n\right )}{n} \]

Antiderivative was successfully verified.

[In]

Integrate[Cos[a + b*x^n]/x,x]

[Out]

(Cos[a]*CosIntegral[b*x^n] - Sin[a]*SinIntegral[b*x^n])/n

________________________________________________________________________________________

Maple [A]  time = 0.034, size = 25, normalized size = 1. \begin{align*}{\frac{-{\it Si} \left ( b{x}^{n} \right ) \sin \left ( a \right ) +{\it Ci} \left ( b{x}^{n} \right ) \cos \left ( a \right ) }{n}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cos(a+b*x^n)/x,x)

[Out]

1/n*(-Si(b*x^n)*sin(a)+Ci(b*x^n)*cos(a))

________________________________________________________________________________________

Maxima [F(-2)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: IndexError} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(a+b*x^n)/x,x, algorithm="maxima")

[Out]

Exception raised: IndexError

________________________________________________________________________________________

Fricas [A]  time = 1.89521, size = 131, normalized size = 5.04 \begin{align*} \frac{\cos \left (a\right ) \operatorname{Ci}\left (b x^{n}\right ) + \cos \left (a\right ) \operatorname{Ci}\left (-b x^{n}\right ) - 2 \, \sin \left (a\right ) \operatorname{Si}\left (b x^{n}\right )}{2 \, n} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(a+b*x^n)/x,x, algorithm="fricas")

[Out]

1/2*(cos(a)*cos_integral(b*x^n) + cos(a)*cos_integral(-b*x^n) - 2*sin(a)*sin_integral(b*x^n))/n

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{\cos{\left (a + b x^{n} \right )}}{x}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(a+b*x**n)/x,x)

[Out]

Integral(cos(a + b*x**n)/x, x)

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{\cos \left (b x^{n} + a\right )}{x}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(a+b*x^n)/x,x, algorithm="giac")

[Out]

integrate(cos(b*x^n + a)/x, x)